<?php
//模型
class ConfigModel extends MY_Model {
	function __construct(){
		parent::__construct();
		$this->table = 'config';
	}
	
	function get_config($name){
		$sql  = "select * from ".$this->db->dbprefix.$this->table." where name='{$name}' limit 1";
		$query = $this->db->query($sql);
		$row = $query->row_array();
		if(!$row){
			return false;
		}
		return $row['value'];
	}
	
	
}

